import { createApp } from "vue";
import App from "./App.vue";
import router from "./router";
import ElementPlus from "element-plus";
import "element-plus/dist/index.css";
import "vue-aliplayer-v2/dist/css/index.06951331.css";
import "bootstrap-icons/font/bootstrap-icons.css";
import "@/assets/css/style.css";
import "@/assets/css/dashboard-bootstrap.css";
import "@/assets/css/background.css";
import Particles from "vue3-particles";
import { createPinia } from "pinia";
import VueAliplayerV2 from "vue-aliplayer-v2";
import piniaPluginPersistedstate from "pinia-plugin-persistedstate"; // <--- 1. 引入插件
const app = createApp(App);
const pinia = createPinia(); // <--- 2. 创建 Pinia 实例
pinia.use(piniaPluginPersistedstate); // <--- 3. 使用插件
app.use(router);
app.use(ElementPlus);
app.use(pinia);
app.use(Particles);
app.use(VueAliplayerV2);
if (import.meta.env.MODE === "development") {
  window.__PINIA__ = true; // 在开发模式中开启调试
}
app.mount("#app");
